<%@include file="menu/util.jsp" %>
<%@ page contentType="application/vnd.ms-excel" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>

<c:set var="scoreDomain" value="${scoreDomain}"/>
<c:set var="dimensionalCutFather" value="${dimensionalCutFather}"/>
<c:set var="scoreDomainDimensionalCutsScores" value="${scoreDomainDimensionalCutsScores}"/>
<c:set var="scoreDomainDimensionalCutsDCs" value="${scoreDomainDimensionalCutsDCs}"/>
<c:set var="tab" value="${tab}"/>


<c:set var="dimensionalCutsScores" value="${scoreDomainDimensionalCutsScores[scoreDomain]}" />
<c:set var="dimensionalCutsDCs" value="${scoreDomainDimensionalCutsDCs[scoreDomain]}" />

<c:set var="dimensionalCuts" value="${dimensionalCutsDCs[dimensionalCutFather]}" />



<fmt:bundle basename="app">

    <c:forEach var="dimensionalCut" items="${dimensionalCuts}">
        <c:set var="scorePojo" value="${dimensionalCutsScores[dimensionalCut]}" />
        <tr>
            <td style="text-align:left">
                ${dimensionalCut.pointer.name}
            </td>
            <td style="text-align:left">
                <c:set var="dimensionalCutMembers" value="${dimensionalCutsMembers[dimensionalCut]}" />
                <c:out escapeXml="false" value="${tab}"/>(${dimensionalCutMembers})
            </td>
            <td><fmt:formatNumber maxFractionDigits="5" value="${scorePojo.real}" /></td>
            <td><fmt:formatNumber maxFractionDigits="5" value="${scorePojo.target}" /></td>
            <td><fmt:formatNumber type="percent" value="${scorePojo.score}" /></td>
        </tr>

        <c:if test="${!empty dimensionalCutsDCs[dimensionalCut]}">

            <c:set var="scoreDomain" value="${scoreDomain}" scope="request"/>
            <c:set var="dimensionalCutFather" value="${dimensionalCut}" scope="request"/>
            <c:set var="scoreDomainDimensionalCutsScores" value="${scoreDomainDimensionalCutsScores}" scope="request"/>
            <c:set var="scoreDomainDimensionalCutsDCs" value="${scoreDomainDimensionalCutsDCs}" scope="request"/>
            <c:set var="tab" scope="request">
                ${tab}&nbsp;&nbsp;&nbsp;
            </c:set>

            <jsp:include page="drillPointerReport.jsp" />

        </c:if>
    </c:forEach>



</fmt:bundle>